<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
    <title>登录页面</title>
    <link rel="stylesheet" href="../../css/bootstrap.min.css"/>
    <link rel="stylesheet" href="../../css/font-awesome.min.css"/>
    <link rel="stylesheet" href="../../css/ace.min.css"/>
    <link rel="stylesheet" href="../../css/ace-rtl.min.css"/>
    <script type="text/javascript" src="../../js/jquery-2.0.3.min.js"></script>
    <script type="text/javascript" src="../../js/plugins/md5/jquery.md5.js"></script>
    <script type="text/javascript">
        login = function() {
            var userName = $("[type='text']").val();
            var password = $("[type='password']").val();
            $("[type='password']").val($.md5(password));
            if (!userName || !password) {
                return false;
            }
        }
    </script>
</head>
<body class="login-layout">
<div class="main-container">
    <div class="main-content">
        <div class="row">
            <div class="col-sm-10 col-sm-offset-1">
                <div class="login-container" style="margin-top: 15%">
                    <div class="center">
                        <h1>
                            <i class="icon-leaf green"></i> <span class="red">myCat</span> <span class="white">Application</span>
                        </h1>
                        <h4 class="blue">&copy; Company Name</h4>
                    </div>

                    <div class="space-6"></div>

                    <div class="position-relative">
                        <div id="login-box" class="login-box visible widget-box no-border">
                            <div class="widget-body">
                                <div class="widget-main">
                                    <h4 class="header blue lighter bigger">
                                        <i class="icon-coffee green"></i> Please Enter Your Information
                                    </h4>

                                    <div class="space-6"></div>
                                    <form action="/login" method="post" onsubmit="return login()">
                                        <fieldset>
                                            <label class="block clearfix">
													<span class="block input-icon input-icon-right">
														<input type="text" required name="userName" value="${userName}"
                                                               class="form-control" placeholder="Username"/>
														<i class="icon-user"></i>
													</span>
                                            </label>
                                            <label class="block clearfix">
													<span class="block input-icon input-icon-right">
														<input type="password" required name="password" value=""
                                                               class="form-control" placeholder="Password"/>
														<i class="icon-lock"></i>
													</span>
                                            </label>
                                            <label class="block clearfix">
                                                <i>${errorMsg} </i>
                                            </label>

                                            <div class="clearfix">
                                                <label class="inline">
                                                    <input type="checkbox" class="ace" name="rememberMe" value="YES"/> <span class="lbl"> Remember Me</span>
                                                </label>
                                                <button type="submit"
                                                        class="width-35 pull-right btn btn-sm btn-primary">
                                                    <i class="icon-key"></i> Login
                                                </button>
                                            </div>
                                            <div class="space-4"></div>
                                        </fieldset>
                                    </form>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
</body>
</html>